
class OsnTextMessageContent: OsnMessageContent {
    var data = ""

    override init(){
        super.init()
        contentType = OsnMessageContentType.text
    }
    override func toJson() ->[String:Any] {
        var json = super.toJson()
        json["data"] = data
        return json
    }
    static func fromJson(_ data:[String:Any]) ->OsnTextMessageContent {
        let c = OsnTextMessageContent()
        super.fromJson(c, data)
        c.data = data["data"] as? String ?? ""
        return c
    }

}
